.class Lcom/waiqin365/lightapp/im/activity/bq;
.super Ljava/lang/Object;

# interfaces
.implements Ljava/lang/Runnable;


# instance fields
.field final synthetic a:Lcom/waiqin365/lightapp/im/activity/GroupDetailsActivity;


# direct methods
.method constructor <init>(Lcom/waiqin365/lightapp/im/activity/GroupDetailsActivity;)V
    .locals 0

    iput-object p1, p0, Lcom/waiqin365/lightapp/im/activity/bq;->a:Lcom/waiqin365/lightapp/im/activity/GroupDetailsActivity;

    invoke-direct {p0}, Ljava/lang/Object;-><init>()V

    return-void
.end method


# virtual methods
.method public run()V
    .locals 3

    :try_start_0
    invoke-static {}, Lcom/hyphenate/chat/EMClient;->getInstance()Lcom/hyphenate/chat/EMClient;

    move-result-object v0

    invoke-virtual {v0}, Lcom/hyphenate/chat/EMClient;->groupManager()Lcom/hyphenate/chat/EMGroupManager;

    move-result-object v0

    iget-object v1, p0, Lcom/waiqin365/lightapp/im/activity/bq;->a:Lcom/waiqin365/lightapp/im/activity/GroupDetailsActivity;

    invoke-static {v1}, Lcom/waiqin365/lightapp/im/activity/GroupDetailsActivity;->c(Lcom/waiqin365/lightapp/im/activity/GroupDetailsActivity;)Ljava/lang/String;

    move-result-object v1

    invoke-virtual {v0, v1}, Lcom/hyphenate/chat/EMGroupManager;->getGroupFromServer(Ljava/lang/String;)Lcom/hyphenate/chat/EMGroup;

    iget-object v0, p0, Lcom/waiqin365/lightapp/im/activity/bq;->a:Lcom/waiqin365/lightapp/im/activity/GroupDetailsActivity;

    new-instance v1, Ljava/util/ArrayList;

    iget-object v2, p0, Lcom/waiqin365/lightapp/im/activity/bq;->a:Lcom/waiqin365/lightapp/im/activity/GroupDetailsActivity;

    invoke-static {v2}, Lcom/waiqin365/lightapp/im/activity/GroupDetailsActivity;->f(Lcom/waiqin365/lightapp/im/activity/GroupDetailsActivity;)Lcom/hyphenate/chat/EMGroup;

    move-result-object v2

    invoke-virtual {v2}, Lcom/hyphenate/chat/EMGroup;->getMembers()Ljava/util/List;

    move-result-object v2

    invoke-direct {v1, v2}, Ljava/util/ArrayList;-><init>(Ljava/util/Collection;)V

    invoke-static {v0, v1}, Lcom/waiqin365/lightapp/im/activity/GroupDetailsActivity;->a(Lcom/waiqin365/lightapp/im/activity/GroupDetailsActivity;Ljava/util/ArrayList;)Ljava/util/ArrayList;

    iget-object v0, p0, Lcom/waiqin365/lightapp/im/activity/bq;->a:Lcom/waiqin365/lightapp/im/activity/GroupDetailsActivity;

    invoke-static {v0}, Lcom/waiqin365/lightapp/im/activity/GroupDetailsActivity;->f(Lcom/waiqin365/lightapp/im/activity/GroupDetailsActivity;)Lcom/hyphenate/chat/EMGroup;

    move-result-object v0

    invoke-virtual {v0}, Lcom/hyphenate/chat/EMGroup;->getOwner()Ljava/lang/String;

    move-result-object v0

    invoke-static {v0}, Landroid/text/TextUtils;->isEmpty(Ljava/lang/CharSequence;)Z

    move-result v0

    if-nez v0, :cond_0

    iget-object v0, p0, Lcom/waiqin365/lightapp/im/activity/bq;->a:Lcom/waiqin365/lightapp/im/activity/GroupDetailsActivity;

    invoke-static {v0}, Lcom/waiqin365/lightapp/im/activity/GroupDetailsActivity;->d(Lcom/waiqin365/lightapp/im/activity/GroupDetailsActivity;)Ljava/util/ArrayList;

    move-result-object v0

    iget-object v1, p0, Lcom/waiqin365/lightapp/im/activity/bq;->a:Lcom/waiqin365/lightapp/im/activity/GroupDetailsActivity;

    invoke-static {v1}, Lcom/waiqin365/lightapp/im/activity/GroupDetailsActivity;->f(Lcom/waiqin365/lightapp/im/activity/GroupDetailsActivity;)Lcom/hyphenate/chat/EMGroup;

    move-result-object v1

    invoke-virtual {v1}, Lcom/hyphenate/chat/EMGroup;->getOwner()Ljava/lang/String;

    move-result-object v1

    invoke-virtual {v0, v1}, Ljava/util/ArrayList;->remove(Ljava/lang/Object;)Z

    move-result v0

    if-eqz v0, :cond_0

    iget-object v0, p0, Lcom/waiqin365/lightapp/im/activity/bq;->a:Lcom/waiqin365/lightapp/im/activity/GroupDetailsActivity;

    invoke-static {v0}, Lcom/waiqin365/lightapp/im/activity/GroupDetailsActivity;->d(Lcom/waiqin365/lightapp/im/activity/GroupDetailsActivity;)Ljava/util/ArrayList;

    move-result-object v0

    const/4 v1, 0x0

    iget-object v2, p0, Lcom/waiqin365/lightapp/im/activity/bq;->a:Lcom/waiqin365/lightapp/im/activity/GroupDetailsActivity;

    invoke-static {v2}, Lcom/waiqin365/lightapp/im/activity/GroupDetailsActivity;->f(Lcom/waiqin365/lightapp/im/activity/GroupDetailsActivity;)Lcom/hyphenate/chat/EMGroup;

    move-result-object v2

    invoke-virtual {v2}, Lcom/hyphenate/chat/EMGroup;->getOwner()Ljava/lang/String;

    move-result-object v2

    invoke-virtual {v0, v1, v2}, Ljava/util/ArrayList;->add(ILjava/lang/Object;)V

    :cond_0
    iget-object v0, p0, Lcom/waiqin365/lightapp/im/activity/bq;->a:Lcom/waiqin365/lightapp/im/activity/GroupDetailsActivity;

    invoke-static {v0}, Lcom/waiqin365/lightapp/im/activity/GroupDetailsActivity;->e(Lcom/waiqin365/lightapp/im/activity/GroupDetailsActivity;)Lcom/waiqin365/lightapp/im/activity/cn;

    move-result-object v0

    iget-object v1, p0, Lcom/waiqin365/lightapp/im/activity/bq;->a:Lcom/waiqin365/lightapp/im/activity/GroupDetailsActivity;

    invoke-static {v1}, Lcom/waiqin365/lightapp/im/activity/GroupDetailsActivity;->d(Lcom/waiqin365/lightapp/im/activity/GroupDetailsActivity;)Ljava/util/ArrayList;

    move-result-object v1

    invoke-virtual {v0, v1}, Lcom/waiqin365/lightapp/im/activity/cn;->a(Ljava/util/ArrayList;)V

    iget-object v0, p0, Lcom/waiqin365/lightapp/im/activity/bq;->a:Lcom/waiqin365/lightapp/im/activity/GroupDetailsActivity;

    new-instance v1, Lcom/waiqin365/lightapp/im/activity/br;

    invoke-direct {v1, p0}, Lcom/waiqin365/lightapp/im/activity/br;-><init>(Lcom/waiqin365/lightapp/im/activity/bq;)V

    invoke-virtual {v0, v1}, Lcom/waiqin365/lightapp/im/activity/GroupDetailsActivity;->runOnUiThread(Ljava/lang/Runnable;)V
    :try_end_0
    .catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_0

    :goto_0
    return-void

    :catch_0
    move-exception v0

    iget-object v0, p0, Lcom/waiqin365/lightapp/im/activity/bq;->a:Lcom/waiqin365/lightapp/im/activity/GroupDetailsActivity;

    new-instance v1, Lcom/waiqin365/lightapp/im/activity/bs;

    invoke-direct {v1, p0}, Lcom/waiqin365/lightapp/im/activity/bs;-><init>(Lcom/waiqin365/lightapp/im/activity/bq;)V

    invoke-virtual {v0, v1}, Lcom/waiqin365/lightapp/im/activity/GroupDetailsActivity;->runOnUiThread(Ljava/lang/Runnable;)V

    goto :goto_0
.end method
